import { useRouter } from 'vue-router'


export function SaveToken(token) {
	localStorage.setItem("token", token)
}


export function GetToken() {
	return localStorage.getItem("token")
}


export function SaveUser(user) {
	localStorage.setItem("user", JSON.stringify(user))
}

export function GetUser() {
	const userStr = localStorage.getItem("user")
	return JSON.parse(userStr)
}


